home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d3
/
wputil35.arc
/
PDX2WP11.ARC
/
PDX2WP.DOC
< prev
next >
Wrap
Text File
|
1991-02-28
|
44KB
|
1,071 lines
PDX2WP
A Paradox to WordPefect Translation Utility
Shareware Version 1.10
Copyright (c) 1990 S.L.S. Systems
All Rights Reserved.
TABLE OF CONTENTS
License and Warranty Information . . . . . . . . . . . 1
What Is PDX2WP? . . . . . . . . . . . . . . . . . . . . 2
Installing PDX2WP . . . . . . . . . . . . . . . . . . . 3
How to Use the PDX2WP Utility . . . . . . . . . . . . . 4
Running the PDX2WP Utility From the DOS Command
Line . . . . . . . . . . . . . . . . . . . . . 4
Running the PDX2WP Utility From a Paradox PAL
Script . . . . . . . . . . . . . . . . . . . . 5
Running the PDX2WP Utility From Interactive Paradox 7
How to Use the WP2PDX Utility . . . . . . . . . . . . . 9
Running the WP2PDX Utility From the DOS Command
Line . . . . . . . . . . . . . . . . . . . . . 9
Running the PDX2WP Utility From Paradox . . . . . . 10
Limitations of PDX2WP . . . . . . . . . . . . . . . . . 11
Suggestions and Hints . . . . . . . . . . . . . . . . . 13
Final Comments . . . . . . . . . . . . . . . . . . . . 14
Invoice/Registration Form . . . . . . . . . . . . . . . 16
─────────────────────────────────────────────────────────────────
PDX2WP Page i
License and Warranty Information
================================
PDX2WP is not in the public domain. This is a shareware
product. It is fully protected by copyright law.
You are granted without charge a license which permits (a)
use of the program for a reasonable period for evaluation
and testing; (b) making copies for distribution to others
without charge, provided the program and the accompanying
documentation and other files are distributed together and
without modification; (c) posting the program, together
with the accompanying documentation and other files, on
electronic bulletin board systems.
How long is a reasonable period? The idea of shareware is
that you should be able to try a program before deciding to
buy it. Once you have tried PDX2WP and found that it is
useful to you you should begin to realize its benefits. A
period of two weeks after first use should be sufficient to
determine the program's usefulness. Any time after the two
weeks is unreasonable.
Use after the reasonable evaluation and testing period re-
quires payment of a license fee. For a single copy (plus
necessary archival copies), to be used on only one computer
at a time, the fee is $30.00. For your convenience, an
invoice form is included at the end of this documentation.
For large quantities, discounts and site licenses are avail-
able. Write for information.
PDX2WP is licensed, and the documentation and other included
files are provided "AS IS," without any warranty as to
performance, accuracy, or freedom from error, or as to any
results generated through use of such material, including,
without limitation, any implied warranties of merchantabili-
ty or fitness for a particular purpose.
Paradox is a trademark of Borland International
WordPerfect is a registered trademark of WordPerfect Corpo-
ration
S.L.S. Systems
13 Shirley Ave.
Kingston, Massachusetts 02364
617-585-3620
─────────────────────────────────────────────────────────────────
PDX2WP Page 1
What Is PDX2WP?
===============
PDX2WP is actually a pair of utilities, PDX2WP and WP2PDX,
which will perform translation of Paradox tables into Word-
Perfect documents or WordPerfect secondary merge documents
into Paradox tables. The documents created by PDX2WP are
meant for use with WordPerfect version 5.0 or later, while
the documents converted by WP2PDX must already exist as
WordPerfect version 5.0 or later secondary merge documents.
It is important to note that neither PDX2WP nor WP2PDX
require the presence of either Paradox or WordPerfect. All
that is required to run PDX2WP is an existing Paradox table
which will be translated, while WP2PDX only requires an
existing WordPerfect secondary merge document. It must also
be noted that neither PDX2WP nor WP2PDX affect or alter the
original Paradox table or WordPerfect document in any man-
ner.
The WordPerfect document which is created by PDX2WP may be
any of three formats:
-- A WordPerfect table, with rows and columns, similar
in appearance to a spreadsheet. In this format, each
Paradox record becomes a row in the WordPerfect
table, with each column representing a field of the
record (up to the WordPerfect limit of 32 columns).
The maximum number of rows in a WordPerfect table is
32,765. WordPerfect tables may be used only with
versions 5.1 or later of WordPerfect.
-- WordPerfect parallel columns, where blocks of text
are separated into columns which are printed side-
by-side. With PDX2WP each field of the Paradox
record is entered into a column, with as many col-
umns as there are fields in the Paradox table (up to
the WordPerfect limit of 24 columns).
-- WordPerfect secondary merge file, where a secondary
merge record is created for each record in the
Paradox table. A merge field is created for each
field in the Paradox record. There is no limit on
the number of fields for a secondary merge record.
─────────────────────────────────────────────────────────────────
PDX2WP Page 2
The WordPerfect document to be converted by WP2PDX must be a
secondary merge document, created by WordPerfect version 5.0
or later. It must be a document set up with individual re-
cords, separated by WordPerfect "end of record" merge codes
(either ^E or {END RECORD}). Each record must be broken
into fields, each separated by WordPerfect "end of field"
codes (either ^R or {END FIELD}).
This shareware version of PDX2WP and WP2PDX are command-line
oriented programs. This means that there are no menus, win-
dows, data entry forms, or other user interface. All op-
tions to the programs are specified as parameters to the
programs when run from the DOS command line.
Installing PDX2WP
=================
As mentioned earlier, PDX2WP is actually two utilities.
Each of these utilities is a self-contained executable
program file, PDX2WP.EXE and WP2PDX.EXE. Simply insert the
distribution disk into your floppy disk drive and copy these
two programs from the distribution disk to a directory which
is included in your DOS path. For example, if you have a
directory named \UTILITY in which you keep all utilities,
copy the two program files into the \UTILITY directory using
the DOS "copy" command, as follows:
copy a:*.exe c:\utility
Included with the two executable programs are the following
files:
PDX2WP.DOC This documentation file.
PDX2WP.SC A Paradox script which can be used to
execute PDX2WP from within interactive
Paradox.
INIT.SC A Paradox startup script which, when
placed in the Paradox startup directory
(i.e., \PARADOX3) will assign the
PDX2WP.SC script to the Shift-F5 key.
This file should be modified to direct
Paradox to the directory to which
PDX2WP.SC was copied.
CONTACTS.DB A sample Paradox table for use as an
example for PDX2WP.
─────────────────────────────────────────────────────────────────
PDX2WP Page 3
MAILLIST.DOC A sample WordPerfect secondary merge
document for use as an example for WP-
2PDX.
Copy the above files to appropriate directories, and both
PDX2WP and WP2Pdx will be ready to run, from either the DOS
command line or from within Paradox.
How to Use the PDX2WP Utility
=============================
PDX2WP may be run from either the DOS command line or from
within a Paradox PAL script. By creating a short PAL script
and attaching the script to a key combination in Paradox
using the SETKEY command, the program may also be run from
interactive Paradox. (Although WordPerfect provides the
capability to run a DOS command, there is not enough memory
available to run PDX2WP while WordPerfect is running.)
Running the PDX2WP Utility From the DOS Command Line
----------------------------------------------------
When running PDX2WP from the DOS command line, you must
specify the name of the WordPerfect document you wish to
create, the name of the Paradox table you wish to trans-
late, and a "switch" specifying which type of WordPer-
fect document you wish to create.
The syntax for PDX2WP is:
PDX2WP document-name table-name /type
"Document-name" is the name of the WordPerfect document
you wish to create. You may include a drive specifier,
a full path name, and a file name. The file name fol-
lows standard DOS naming conventions: a name of up to 8
characters, followed by an optional period and an exten-
sion of up to 3 characters. The following are all valid
names for a WordPerfect document:
MY-FILE
PDX-TABL.DOC
B:NAMES
C:\WP\DOCUMENT\MAILLIST.WP
─────────────────────────────────────────────────────────────────
PDX2WP Page 4
"Table-name" is the name of the Paradox table which will
be translated. This name may be the name of any valid
Paradox table. As with the document-name, you may
include a drive specifier and a full path name. An
extension of "DB" is assumed. Therefore, do not include
an extension. If an extension is included, an error
message will be displayed.
"Type" represents the type of translation you wish to
perform, and is always preceded by a "/". Valid types
and there meaning are:
T Create a WordPerfect Table (Version 5.1 only)
C Create parallel columns (Version 5.0 or later)
M Create a secondary merge file (Version 5.0 or
later)
The following are examples of valid command-line entries
for the PDX2WP utility:
PDX2WP CONTACTS.WP CONTACTS /M
PDX2WP \ACCOUNT.TBL \PARADOX\FILES\ACCOUNT /T
PDX2WP A:MERGE.NMS NAMES /M
PDX2WP PARTLIST \PARADOX\INVENTORY\PARTS /C
After typing the appropriate command-line entry and
pressing ENTER, several lines of copyright information
are displayed. After the copyright lines is a line
which displays the progress of the conversion process,
showing the record number of each Paradox record as it
is translated. Upon completion, a message indicating
the total number of records translated is displayed.
This number indicates the number of rows in the WordPer-
fect table or column structure, or the number of merge
records created in a secondary merge file.
Running the PDX2WP Utility From a Paradox PAL Script
----------------------------------------------------
By using the PDX2WP utility within a PAL script, the
translation of a Paradox table can be made to execute
automatically, without user intervention. PDX2WP can be
run within a PAL script using the PAL command "RUN BIG"
─────────────────────────────────────────────────────────────────
PDX2WP Page 5
followed by the command-line entry for PDX2WP described
in the previous section.
A common application of this use would be to translate a
Paradox ANSWER table which is created as a result of a
query. This allows for the translation of a selected
subset of records from a Paradox table. Following is an
excerpt of a simple PAL script performing such a query.
The line numbers are shown for information only, and are
not part of the script
1 query
2
3 contacts |Name |Address |City |
4 |check |check |check |
5 | | | |
6 | | | |
7
8
9 contacts |State |Zip Code |
10 |check, MA |check |
11 | | |
12 | | |
13
14 endquery
15
16 Do_It!
17
18 If Istable("Answer") then
19 run big "pdx2wp contacts.wp answer /m"
20 endif
In this example, the first portion of PAL code, from
line 1 to line 14, is a script which was generated using
the Paradox QuerySave command. The script queries the
Paradox table "Contacts," requesting the fields Name,
Address, City, State, and Zip Code, where State is equal
to "MA." By editing the script with the Paradox
Script/Edit command and adding lines 15 through 20, the
script can be made to perform both the query and the
PDX2WP translation of the resulting Answer file.
The "Do_It!" command on line 16 causes Paradox to per-
form the query specified on lines 1 through 14. If
there are any records which satisfy the criteria in the
query command, the Answer table will be created with
─────────────────────────────────────────────────────────────────
PDX2WP Page 6
those selected records and will become the current
table. Otherwise, no Answer table will be created and
the current table will still be the Contacts table.
Line 18 checks to see if the current table is the Answer
table. If so, then line 19 is executed, which actually
runs PDX2WP as if it were entered at the DOS command
line. When PDX2WP completes the translation, control
will return to the PAL script, and any further commands
will be executed.
Running the PDX2WP Utility From Interactive Paradox
---------------------------------------------------
There are two methods of running PDX2WP from the inter-
active Paradox environment. It may be run as a "mini-
cript" using the same statement shown on line 20 of the
above script, or it can be attached to a Paradox "hot-
key" with the SETKEY command.
To execute PDX2WP as a mini-script, access the PAL menu
by pressing Alt-F10. Choose the MiniScript option from
the menu. A message prompting for a command will be
displayed. Type in the command using the RUN BIG com-
mand, as in the example on line 20 of the script above.
Be sure to substitute the appropriate document-name,
table-name and translation type in the command, then
press Enter to execute PDX2WP.
The second method for running PDX2WP from the interac-
tive Paradox environment is by assigning the PDX2WP
command to a key combination. This is done by using the
Paradox SETKEY command in a special PAL script named
"Init."
The Init script resides in the default data directory
for Paradox, and includes any number of functions to be
performed automatically when Paradox is first loaded.
By including a SETKEY command for PDX2WP in the Init
script, the PDX2WP utility may be executed simply by
performing the keystroke to which the program was as-
signed. The following line assigns the PDX2WP command
to the Shift-F5 key combination:
setkey "F15" run big "pdx2wp " + table() + " " + ta-
ble() + " /t"
─────────────────────────────────────────────────────────────────
PDX2WP Page 7
This example again uses the RUN BIG command, as well as
the TABLE() function, which returns the name of the cur-
rent Paradox table, to create a WordPerfect file with
the same name as the Paradox table.
Although this is a simple example, it does not allow the
flexibility of choosing which type of translation to
perform once Paradox is running. By using a combination
of the SETKEY command in the Init script and a separate
script which performs the translation, the choice can be
made at the time the key combination is pressed. Rather
than having the assigned key combination do the actual
translation, a separate script may be played by the as-
signed key combination. The SETKEY statement in the
Init script would then look more like the following:
setkey "F15" play "\\paradox3\\pdx2wp"
The section of the line in quotes after the PLAY command
is the directory and file name of the script to be
played. (When specifying a path or directory in a
script, the subdirectory names must be separated by 2
backwards slashes.)
A complete sample PDX2WP script is included with this
package, and may be used as is or as an example which
may be expanded upon. The sample script first verifies
that a table image is on the Paradox workspace. If
there is no image on the workspace, a message is dis-
played and processing stops, returning to the previous
state. If there is an image on the workspace, a Paradox
menu is displayed. The menu allows the selection of the
translation type which PDX2WP will perform. Once an
option is chosen, the appropriate translation is per-
formed. The WordPerfect document is given a file name
which is the same as the Paradox table name, and an
extension of .COL, .MRG, or .TBL for a parallel columns
document, secondary merge document, or WordPerfect
table, respectively.
By copying the sample script to your Paradox directory
and adding the SETKEY statement to the existing Init
script (or creating an Init script which includes the
SETKEY statement), the PDX2WP translation utility will
be continuously available from within the interactive
Paradox environment.
─────────────────────────────────────────────────────────────────
PDX2WP Page 8
How to Use the WP2PDX Utility
=============================
WP2PDX may also be run from the DOS command line or from
Paradox, either within the interactive environment or from a
PAL script. While the operation of WP2PDX from the DOS com-
mand line is very similar to that of PDX2WP, the use of
WP2PDX from within Paradox is somewhat different. Again, as
with PDX2WP, there generally is not enough memory available
to run WP2PDX from WordPerfect's "Go To Dos" or "Dos Com-
mand" options.
Running the WP2PDX Utility From the DOS Command Line
----------------------------------------------------
When running WP2PDX from the DOS command line, you must
specify the name of the WordPerfect secondary merge
document you wish to convert and the name of the Paradox
table you wish to create. Since there is only one type
of Paradox table, there are no additional parameters to
the WP2PDX utility.
The syntax for WP2PDX is:
WP2PDX document-name table-name
"Document-name" is the name of the WordPerfect document
you wish to convert. You may include a drive specifier,
a full path name, and a file name. The file name fol-
lows standard DOS naming conventions: a name of up to 8
characters, followed by an optional period and an exten-
sion of up to 3 characters. The following are all valid
names for a WordPerfect document:
MY-FILE
PDX-TABL.DOC
B:NAMES
C:\WP\DOCUMENT\MAILLIST.WP
"Table-name" is the name of the Paradox table which will
be created. This name may be any valid Paradox table
name. As with the document-name, you may include a
drive specifier and a full path name. An extension of
"DB" is assumed. Therefore, do not include an exten-
─────────────────────────────────────────────────────────────────
PDX2WP Page 9
sion. If an extension is included, an error message
will be displayed.
The following are examples of valid command-line entries
for the WP2PDX utility:
WP2PDX CONTACTS.WP CONTACTS
WP2PDX \ACCOUNTS.MRG \PARADOX\FILES\ACCOUNTS
WP2PDX A:MERGE.NMS NAMES
WP2PDX PARTLIST C:\PARADOX\INVENTORY\PARTS
After typing the appropriate command-line entry and
pressing ENTER, several lines of copyright information
are displayed. WP2PDX then performs the first of three
steps: veryifying that the specified document is a
WordPerfect secondary merge document. This is done by
scanning the document for either "end of field" or "end
of record" merge codes. If no such codes are found, an
error message is displayed and the WP2PDX program termi-
nates.
If the appropriate merge codes are found in the speci-
fied merge document, the next step in the conversion
process is performed. In this step, the document is
analyzed to determine the structure of the individual
records in the merge document. The structure specifies
how many fields are in each record, how long each field
is (up to the Paradox maximum of 255 characters), and
what type each field is. While this analysis is being
performed, the following message is displayed:
Analyzing WordPerfect document. Please wait
followed by a rotating dash or slash character. The
rotating character is displayed as a visual confirmation
that the program is actually working.
After the analysis is complete, the actual conversion
step begins. During the conversion, a line is displayed
which shows the progress of the conversion, showing the
record number of each Paradox record as it is being
created. Upon completion, a message indicating the total
number of records translated is displayed.
Running the PDX2WP Utility From Paradox
---------------------------------------
─────────────────────────────────────────────────────────────────
PDX2WP Page 10
Since WP2PDX creates a Paradox table, rather than ex-
tracts data from one, there are fewer practical uses of
WP2PDX within the Paradox environment. One example
would be to use the miniscript option from the PAL menu
(Alt-F10). At the "Command:" prompt, use the Paradox
RUN BIG command, as follows:
run big "wp2pdx my-doc.mrg tablname"
This would create a Paradox table which could then be
viewed and manipulated within the Paradox environment.
The same command could be similarly used within a PAL
script.
Limitations of PDX2WP
=====================
This version of PDX2WP is a shareware product, and has
several limitations. Though it is a totally functional and
useful program, there are several limitations and default
settings which may not be overridden. Most of these will be
addressed in a forthcoming commercial version of the prod-
uct, which should be available sometime in the first half of
1991. Where appropriate, the differences between the share-
ware version and the commercial version are noted.
-- Paradox date fields are translated to the standard
MM/DD/YY format. The commercial version will pro-
vide the choice between this format and several
others.
-- When translating to a WordPerfect table, number
fields are decimal aligned in the cell, with 2
decimal places. The commercial version will allow
selection of numeric formats, including commas,
decimal places, and currency notations.
-- All fields in the Paradox table are translated and
placed into separate columns or fields, and in the
same order as they appear in the Paradox table
structure. The commercial version will allow the
selection of specific fields in a user-defined
order. It will also allow the joining of two or
more fields together, separated by a carriage re-
turn, a space, or other special characters or codes.
─────────────────────────────────────────────────────────────────
PDX2WP Page 11
-- When translating to a WordPerfect table, the Paradox
field names are entered into the first row of the
WordPerfect table to serve as headers for the table
structure. This will be an option in the commercial
version.
-- When translating to a secondary merge file, no field
names are defined. Translation occurs using the
standard ^E and ^R separators used in versions prior
to 5.1. The commercial version will provide an
option to use the version 5.1 {FIELD NAMES}, {END
FIELD} and {END RECORD} codes.
-- When translating to a parallel columns format, only
the first 24 fields from the Paradox table are con-
verted. This is a limitation in the number of
columns that WordPerfect allows, rather than a
limitation of PDX2WP.
-- When translating to a WordPerfect table, only the
first 32 fields and the first 32,765 records are
translated. Again, this is a limitation in the
number of columns and rows that WordPerfect allows,
not a limitation of PDX2WP.
-- Since PDX2WP has no knowledge of printer definitions
used in a particular installation of WordPerfect,
there is no printer information included in the
created document files. This restricts these docu-
ments from being printed from the List Files mode of
WordPerfect. They must first be retrieved into
WordPerfect, so they may be formatted for the de-
fault printer then printed.
-- When translating to either parallel columns or a
WordPerfect table, the document is created with a
portrait page layout with 1" left and right margins.
The columns are all created the same size, based on
the page layout and margin size. The commercial
version will allow selection of portrait or land-
scape mode, as well as user-definable left, right,
top, and bottom margins.
-- Password protected tables are not supported by this
version of PDX2WP. The commercial version will pro-
vide facilities for accessing protected tables.
─────────────────────────────────────────────────────────────────
PDX2WP Page 12
-- Access to Paradox tables on a local area network is
not supported by this version of PDX2WP. Again,
network support will be available in the commercial
version of PDX2WP.
-- Access to protected WordPerfect documents is not
supported. A message stating that the WordPerfect
document is password protected is displayed, and the
program terminates.
-- The WP2PDX utility currently interprets all fields
in a secondary merge document as alphanumeric. This
means that the Paradox table will not have any
numeric, dollar, or date fields. Future versions of
WP2PDX will provide support for these field types.
-- With both utilities, if the document or table to be
created already exists, the existing file will be
replaced by the newly created file.
Suggestions and Hints
=====================
Listed below are some helpful ideas and suggestions for get-
ting the most from PDX2WP.
-- If you are already using Paradox, you can translate
only the fields you need by using the query-by-
example capabilities of Paradox. When querying, use
the F6 key to check only those fields which you wish
to be translated into WordPerfect. The resulting
Answer table will only include the fields that have
been checked with the F6 key. Then use PDX2WP to
translate the Answer table.
-- When creating a WordPerfect table, all columns are
set to equal widths. Once the document has been
created, the column widths may be easily changed
using table edit mode (Alt-F7). All aspects of the
table may be changed in this manner.
-- Similarly, when creating parallel columns, all
columns are set to equal widths. Column widths and
margins may be set using the Column Definition
─────────────────────────────────────────────────────────────────
PDX2WP Page 13
command (Alt-F7). This is a bit more cumbersome
than changing column widths in a table.
-- It may be useful to change the orientation of the
page from portrait mode to landscape mode by select-
ing a different paper size using the Page Format
command. This will allow the use of wider columns
in both tables and parallel columns.
-- When creating a WordPerfect table, be aware that
there are considerably more codes required to create
a table than to create parallel columns. Your final
document may be as much as 7 to 10 times larger than
the equivalent Paradox table translated to parallel
columns.
-- When initially creating a secondary merge document
within WordPerfect, don't put too much information
into a single field. For example, split the mailing
address into four or five fields: Street, City,
State, Zip code. This will not only allow more
flexibility within the created Paradox table, it
will also allow greater flexibility within WordPer-
fect when using selection and sorting capabilities
while merging. It will also reduce the possibility
of having information beyond 255 characters in a
single field trimmed from the field when converting
to a Paradox table.
Final Comments
==============
As mentioned earlier, this version of PDX2WP is a shareware
product. It is not in the public domain, nor is it "Free-
ware." As such, you are expected to register your copy of
PDX2WP by filling out the Invoice/Registration Form which
appears at the end of this document.
As a registered user, you will be made aware of all future
versions of PDX2WP, commercial as well as shareware. If you
decide to upgrade to the commercial version when it becomes
available, your registration fee will be credited toward the
price of the commercial version. You will also be made
aware of other utilities and programs from S. L. S. Systems
as they become available.
─────────────────────────────────────────────────────────────────
PDX2WP Page 14
Your comments and suggestions regarding PDX2WP are welcome.
You have the opportunity to impact the future of this pro-
gram, as well as provide input for the development of other
useful utilities and programs.
S. L. S. Systems may be reached through Electronic Mail on
Compuserve (account number 76104,2074) or by mail at the
address on the Invoice/Registration Form.
─────────────────────────────────────────────────────────────────
PDX2WP Page 15
Invoice/Registration Form
=========================
Date: __________
S. L. S. Systems
13 Shirley Avenue
Kingston, MA 02364
SOLD TO:
Name: ___________________________________
Company: ___________________________________
Address: ___________________________________
___________________________________
Phone: (_____) ___________________
FAX: (_____) ___________________
┌────────────────────────────────────────┬─────────────────┐
│ Description │ Price │
├────────────────────────────────────────┼─────────────────┤
│ License for PDX2WP Version 1.10 │ $ 30.00 │
│ │ │
│ ____ additional licenses @ $30.00 │ _________ │
│ │ │
│ │ │
│ │ │
└────────────────────────────────────────┼─────────────────┤
Total Amount Enclosed │ $ │
└─────────────────┘
Please make checks payable to:
S. L. S. Systems
13 Shirley Avenue
Kingston, MA 02364